<!-- Begining of albums list -->
<table>
  <tr>
    <td align="right" width="200">Search albums by name <img src="images/selected-icons/search.png" class="icon" alt="" title="" /></td>
    <td>
<div class="search-form">
<form method="post" action="albums-search.php" name="albums-livesearch" id="albums-livesearch-form">
	<div class="search-bar">
		<input type="text" name="search_albums" value="{$search_albums}" id="search_albums" />
		<input type="submit" name="search-button" value="Search" class="submit" />
	</div>
	<div id="livesearch-results"></div>
</form>
</div>
	</td>
  </tr>
  <tr>
    <td align="right">
		<a href="configurations-list.php">Change ALBUMS PATH</a> 
		<img src="images/folder_add.png" class="icon" title="Add folder on server" alt="Add folder on server" /></td>
    <td><strong>{'FTPPATH_ALBUMS'|constant}</strong> ({'FTPPATH_ALBUMS'|constant|validdirectory})</td>
  </tr>
  <tr>
    <td align="right">
		<a href="configurations-list.php">Change THUMNAILS PATH</a> 
		<img src="images/folder_add.png" class="icon" title="Add folder on server" alt="Add folder on server" /></td>
    <td><strong>{'FTPPATH_THUMBNAILS'|constant}</strong> ({'FTPPATH_THUMBNAILS'|constant|validdirectory}) - <strong style="color:#0000FF;">chmod -R 777</strong></td>
  </tr>
  <tr>
    <td align="right">Add Server/FTP Folder <img src="images/folder_add.png" class="icon" title="Add folder on server" alt="Add folder on server" /></td>
    <td>
<form name="add-albums" method="post" action="albums-add-server.php">
	<input name="album[folder]" value="" type="text" /> <input name="submit-album-folder" type="submit" value="Add" />
</form>	</td>
  </tr>
</table>

<div class="clear" style="clear:both;"></div>

<div class="top-action">
	<ul class="links">
		<li class="record-add"><a href="albums-add.php">Add Albums</a></li>
	</ul>
</div>

<div class="clear" style="clear:both;"></div>

{if $albumss|count}

<div class="form-wrap">
<form id="albums-list-form" name="albums-list-form" method="post" action="albums-blockaction.php">
<table class="data" id="data-table">

<!--{* <caption>List of Albums</caption> *}-->

<thead>
	<tr class="thead">
	  <th><input type="checkbox" id="albums-checkall" name="checkallentities" value="checkallentities" tabindex="0" /></th>
		<th class="th-sn">S.N.</th>
		<th>&nbsp;</th>
		<th>
			<a href="albums-flag.php?flag=is_locked&amp;id=1all&amp;code=skip&amp;invert=true" onclick="return(window.confirm('Rever all?'));">
				<img src="images/selected-icons/locked.png" class="icon" title="Lock an album" alt="Lock an album" />
			</a>
		</th>
		<th>#ID</th>
		<th>Album Name</th>
		<th>Folder - Valid | <span style="color:#FF0000; text-decoration:line-through;">Invalid</span></th>
		<th>Cover Image</th>
		<th class="th-menus">#<input type="checkbox" id="albums-checkall_empty" name="checkallemtpyentities" value="checkallemtpyentities" tabindex="0" /></th>
		<th class="th-menus">Sizes</th>
		<th class="th-menus">Browse</th>
		<th class="th-menus">?</th>
	</tr>
</thead>

<tbody>
{section name='l' loop=$albumss}
	<tr class="{cycle values='A,B'}">
	  <td><input type="checkbox" name="albums[]" value="{$albumss[l].album_id}" /></td>
		<td class="r">{$smarty.section.l.index_next+$pagination->begining_entry()}.</td>
		<td><a href="albums-flag.php?flag=is_approved&amp;id={$albumss[l].album_id}&amp;code={$albumss[l].code}">{$albumss[l].is_approved|yn}</a></td>
		<td><a href="albums-flag.php?flag=is_locked&amp;id={$albumss[l].album_id}&amp;code={$albumss[l].code}">{$albumss[l].is_locked|yn}</a></td>
		<td class="r"><strong>{$albumss[l].album_id}</strong></td>
		<td title="{$albumss[l].album_name|utf8}"><a href="albums-details.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}">{$albumss[l].album_name|partial:30}</a></td>
		<td title="{$albumss[l].album_folder}" style="{if not $albumss[l].album_folder|validdirectory:true}text-decoration:line-through;color:#FF0000;{/if}{if ''==$albumss[l].album_folder}background-color:#FF0000;{/if}"><a href="images-albums-admin.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}">{$albumss[l].album_folder|partial:30}</a></td>
		<td style="{if !$albumss[l].album_coverimage}background-color:#FF0000;{/if}">
			<a href="images-details.php?id={$albumss[l].album_coverimage|imageid}" title="Edit">E</a> |
			<a href="image/{$albumss[l].album_coverimage}" target="_blank">{$albumss[l].album_coverimage}</a>
		</td>
		<td class="r {$albumss[l].images_counter|emptyclass}">{$albumss[l].images_counter}</td>
		<td><a href="albumsizes-list.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}">Manage</a></td>
		<td>
			<!--<a href="images-albums.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}">Browse</a>-->
			<a href="images-albums-admin.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}">Browse</a>
		</td>
		<td class="actions nowrap"><ul>
			<li class="edit"><a href="albums-edit.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}" title="Edit">Edit</a></li>
			<!--{*<li class="detail"><a href="albums-details.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}" title="Details">Details</a></li>
			<li class="delete"><a href="albums-delete.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}" title="Delete" class="delete">Delete</a></li>*}-->
			<li class="scan"><a href="albums-scan.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}" title="(Re)Scan">Scan</a></li>
			<li class="verify"><a href="albums-verify.php?id={$albumss[l].album_id}&amp;code={$albumss[l].code}" title="Verify Images">Verify</a></li>
		</ul></td>
	</tr>
{sectionelse}
	<tr class="error">
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
		<td>-</td>
	</tr>
{/section}
</tbody>
</table>
<div class="block-actions">
	With selected records, <input type="hidden" name="action" value="nothing" />
	<select name="actions" id="actions">
		<option value="">-- Choose --</option>
		<option value="delete">Delete</option>
		<option value="disable">Disable</option>
		<option value="enable" disabled="disabled">Enable</option>
		<option value="enable">Verify images</option>
		<option value="nothing" selected="selected">Do nothing</option>
	</select>
	<input type="submit" name="submit-button" id="submit-button" value="Perform!" />
</div>
</form>
</div>

<p><strong>Notes</strong>: View the album details page to enable all images inside it.</p>

<!-- paginator -->
{if $pagination->has_pages()}
<div class="paginator">
	<span class="introduction">Jump to page: </span>
	{paginate separator=' ' ulli=false source=$pagination}
</div>
{/if}


<!-- Javascript Handlers, Ajax, and Validators -->
{js src='ajax.js'}
{js src='validators/albums/list.js' validator=true}

{else}
	<div class="nodata">You do not have any records here.</div>
{/if}

<!-- End of albums List -->